<el-aside id="el-aside" class="el-aside" :width="aside_width">
  <div class="block">
    <el-avatar v-if="isCollapse === true" class="el-left" :size="40"
      src="__STATIC__/images/zcy.jpeg">
    </el-avatar>

    <div class="el-search" v-if="isCollapse === false">
      <a style="color: #409eff; text-decoration: none;" href="{:url('/admin/index/index')}">最常用出租屋管理系统</a>
    </div>
    <div style="clear: both;"></div>
  </div>

  <el-menu default-active="{$current_route_id}" class="el-menu-vertical-demo" background-color="#222d32"
    text-color="#FFFFFF" active-text-color="#409eff" :collapse="isCollapse">
    {foreach $layout_menu as $v}
    <el-submenu index="{$v.id}">
      <template #title>
        <i class="el-icon-{$v.icon}"></i>
        <span>{$v.name}</span>
      </template>
      {if $v.sub}
      {foreach $v.sub as $vv}
      <a href="/admin/{$vv.controller}/index">
        <el-menu-item index="{$vv.id}">
          <template #title>
            <i v-if="{$current_route_id} == {$vv.id}" class="el-icon-arrow-right"></i>
            <i v-if="{$current_route_id} != {$vv.id}" class="el-icon-arrow-left"></i>
            <span>{$vv.name}</span>
          </template>
        </el-menu-item>
      </a>
      {/foreach}
      {/if}
    </el-submenu>
    {/foreach}
  </el-menu>
</el-aside>